package service.community;

import dao.community.CommunityMapper;
import pojo.Admin;
import pojo.Community;

import java.util.List;

public class CommunityImpl implements CommunityService{
    private CommunityMapper communityMapper;

    public void setCommunityMapper(CommunityMapper communityMapper) {
        this.communityMapper = communityMapper;
    }


    @Override
    public Community queryBynumber(String number) {
        return communityMapper.queryBynumber(number);
    }

    @Override
    public int addCommunity(Community community) {
        return communityMapper.addCommunity(community);
    }

    @Override
    public List<Community> allCommunities() {
        return communityMapper.allCommunities();
    }
}
